Next | Prev | Up | Top | Contents | Index

Checking for Adequate Free Disk Space

XFS filesystems may require more disk space than EFS filesystems for the same files. This extra disk space is required to accommodate the XFS log and as a result of block sizes larger than EFS's 512 bytes. However, XFS represents free space more compactly, on average, and the inodes are allocated dynamically by XFS, which can result in less disk space usage.

This procedure can be used to get a rough idea of the amount of free disk space that will remain after a filesystem is converted to XFS:

  1. Get the size in kilobytes of the filesystem to be converted and round the result to the next megabyte. For example,

    df -k

    Filesystem Type kbytes use avail %use Mounted on

    /dev/root efs 969857 663306 306551 68% /

    This filesystem is 969857 KB, which rounds up to 970 MB.

  2. If you plan to use an internal log (see the section "Choosing the Log Type and Size" in this chapter), give this command to get an estimate of the disk space required for the files in the filesystem after conversion:

    % xfs_estimate -i logsize -b blocksize mountpoint

    logsize is the size of the log. blocksize is the block size you chose for user files in the section "Choosing the Filesystem Block Size and Extent Size" in this chapter. mountpoint is the directory that is the mount point for the filesystem. For example,

    % xfs_estimate -i 1m -b 4096 /

    / will take about 747 megabytes

    The output of this command tells you how much disk space the files in the filesystem (with a blocksize of 4096 bytes) and an internal log of size logsize will take after conversion to XFS.

  3. If you plan to use an external log, give this command to get an estimate of the disk space required for the files in the filesystem after conversion:

    % xfs_estimate -e 0 -b blocksize mountpoint

    blocksize is the block size you chose for user files in the section "Choosing the Filesystem Block Size and Extent Size" in this chapter. mountpoint is the directory that is the mount point for the filesystem. For example,

    % xfs_estimate -e 0 -b 4096 /

    / will take about 746 megabytes

    with the external log using 0 blocks or about 1 megabytes

    The first line of output from xfs_estimate tells you how much disk space the files in the filesystem will take after conversion to XFS. In addition to this, you will need disk space on a different disk partition for the external log. You should ignore the second line of output.

  1. Compare the size of the filesystem from step 1 with the size of the files from step 2 or step 3. For example,

    970 MB - 747 MB = 223 MB free disk space

    747 MB / 970 MB = 77% full

    Use this information to decide if there will be an adequate amount of free disk space if this filesystem is converted to XFS.

If the amount of free disk space after conversion is not adequate, some options to consider are:


Next | Prev | Up | Top | Contents | Index